<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/common/taglibs.jsp" %>

<html>
<head>
    <title>申请售后维护维护</title>
    <meta name="menu" content="queuedTasks"/>
    <script type="text/javascript">
        $(document).ready(function() {
            var grade = '${grade}';
            if (grade) {
                $("#grade" + grade).attr("checked", true);
            } else{
                $("#grade0").attr("checked", true);
            }
           $(':radio:not(:checked)').attr('disabled', ${readonly});
        })
        function submitForm() {
            $('#inputForm').submit()
        }
    </script>
</head>
<body>
<div class="jquery_tab">
    <div class="content_block">
        <h2 class="jquery_tab_title">${task.name}</h2>

        <form id="inputForm" action="aftersales!gradeTask.action" method="post">
            <%@include file="aftersalesCommonForm.jsp" %>

            <p>
                <label for="expectTime">预计完成时间：</label>
                <input class="input-small" type="text" name="expectTime" id="expectTime"
                       value="<s:date name='expectTime' format="yyyy-MM-dd"/>" readonly="true">
            </p>

            <p>
                <label for="endTime">实际完成时间：</label>
                <input class="input-small" type="text" name="endTime" id="endTime"
                       value="<s:date name='endTime' format="yyyy-MM-dd"/>" readonly="true">
            </p>

            <p>
                <label for="grade1">评分:</label>
                <label for="grade0" class="inline">0</label>
                <input id="grade0" name="grade" type="radio" value="0" class="jquery_improved"/>
                <label for="grade1" class="inline">1</label>
                <input id="grade1" name="grade" type="radio" value="1" class="jquery_improved" />

                <label for="grade2" class="inline">2</label>
                <input id="grade2" name="grade" type="radio" value="2" class="jquery_improved"/>

                <label for="grade3" class="inline">3</label>
                <input id="grade3" name="grade" type="radio" value="3" class="jquery_improved"/>

                <label for="grade4" class="inline">4</label>
                <input id="grade4" name="grade" type="radio" value="4" class="jquery_improved"/>

                <label for="grade5" class="inline">5</label>
                <input id="grade5" name="grade" type="radio" value="5" class="jquery_improved"/>
            </p>

            <%@include file="/WEB-INF/content/workflow/comment.jsp" %>
            <p>
                <c:if test="${!readonly}">
                <a class="button" href="javascript:submitForm();"><span>提交</span></a>
                 </c:if>
                <a class="button" onclick="javascript:history.back()"><span>返回</span></a>
            </p>

        </form>
    </div>
</div>
<div class="jquery_tab">
    <%@include file="/WEB-INF/content/workflow/ProcessImage.jsp" %>
</div>

</body>
</html>
